<template>
  <div >
    <el-dialog title="查看" :visible.sync="dialogShow" width="580px" @close="closeDialog" :close-on-click-modal='false'>
      <div class="disposeDialog_box dialogRightGray">
        <div class="form_Dialog_box form_DialogText_box">
          <el-form :model="dialogFrom" label-width="100px" >
            <el-form-item label="买家会员名：" class="form_dialog_item">
              <div class="color_black form_Dialog_text_1">{{dialogFrom.receiver}}</div>
            </el-form-item>
            <el-form-item label="商品名称：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.title}}</div>
            </el-form-item>
            <el-form-item label="退货数量：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.refundNum}}</div>
            </el-form-item>
            <el-form-item label="退款原因：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.refundReason}}</div>
            </el-form-item>
            <el-form-item label="处理状态：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.sellerHandle | statusFil}}</div>
            </el-form-item>
            <el-form-item label="商家备注：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.sellerHandleRemark}}</div>
            </el-form-item>
            <el-form-item label="物流信息：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.shippingName}}{{dialogFrom.shippingCode}}</div>
            </el-form-item>
            <el-form-item label="收货备注：" class="form_dialog_item">
              <div class="color_black form_Dialog_text">{{dialogFrom.confirmReceipt | confirmReceiptFil}}</div>
            </el-form-item>
          </el-form>
        </div>
      </div>
    </el-dialog>
  </div>
</template>

<script>
export default {
  props: ["showTrue",'orderData'],
  data() {
    return {
      labelPosition:'right',
      dialogShow: false,
      dialogFrom:{
        refundOrder:'TKBH156202002021459',
        refundTime:'1589425524000',
        buyerName:'狗剩',
        goodsName:'喔喔',
        refundPrice:'15.62',
        refundReason:'不好',
        refundStatus:'0',
        storeRemarks:'同意',
        refundNum:'1',
        logisticsInfo:'怒风速运 Y2343564758654',
        receiptRemarks:'确认收货完成',
      }
    };
  },
  filters: {
    statusFil(val) {
      if(val==0){
        return '未处理 '
      } else if(val==1){
        return '同意 '
      }else if(val==2){
        return '不同意 '
      }
      // return val ? '同意退款' : '拒绝退款'
    },
    confirmReceiptFil(val){
      if(val==0){
        return '未收货 '
      } else if(val==1){
        return '确认收货完成 '
      }
    }
  },
  watch: {
    showTrue(val) {
      this.dialogShow = val;
    },
    orderData(val){
      this.dialogFrom = {...val}
    }
  },
  created() {},
  mounted() {
  },
  methods: {
    closeDialog(){
      this.$emit("close");
    },
    submitDialog(){
      this.$emit("submit");
    }
  }
};
</script>

<style scoped rel="stylesheet">
.form_dialog_item {
  width: 100% !important;
  margin-bottom: 4px !important;
}

.disposeDialog_box {
  width: 100%;
  overflow: hidden;
}
.form_Dialog_box {
  width: calc(100% - 40px);
  margin: 20px;
  overflow: hidden;
}
.form_DialogText_box {
  margin-bottom: 40px;
}
</style>
